<template>
  <div>
    <Header />
    <router-view></router-view>
    <Footer v-show="!$route.meta.footerIsHidden"/> 
  </div>
</template>

<script>
import Header from "@comp/Header";
import Footer from "@comp/Footer";
import { mapActions } from "vuex";

export default {
  name: "App",
  mounted(){
    //初始化的时候 请求categoryList数据
    this.getCategoryList()
  },
  components: {
    Header,
    Footer,
  },
 methods:{
    //拿到让action去请求三级列表的方法
    ...mapActions("home", ["getCategoryList"]),
 }
 
};
</script>

<style lang="less" scoped>

</style>
